<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
</html>
<script>
    for(var i=0;i<=6;i++){
        for(var k=6;k>i;k--){
			document.write("&nbsp;&nbsp;&nbsp;");
		}		
		for(var j=0;j<=i;j++){
            document.write(j+"&nbsp;");
		}
		for(var h=i-1;h>=0;h--){
            document.write(h+"&nbsp;");
        }
        document.write("<br>");
    }
    
</script>